The present invention relates to the field of video coding systems, and, more particularly, to a system and method for coding frames upon detecting a scene change in a video sequence.
Normally, successive frames in a video sequence are very similar to each other. Most sequences have scenes in which an object moves across a stationary background, or a background moves behind a stationary object. Consequently, many regions in one frame often appear in the next frame, only displaced to a different position in that subsequent frame. Video coding systems, then, take advantage of such redundancy within the frames by using predictive coding techniques, such as motion estimation and motion compensation, to reduce the volume of data for compressing the frames.
At a scene change, however, successive frames are significantly different from each other, causing motion estimation and motion compensation techniques to fail. The scene change leads to substantial prediction errors and annoying quantization artifacts, particularly at low bit rates.
To avoid such artifacts, then, a technique is needed that not only detects scene changes, but also make advantageous use of the scene change during the encoding of the frames to produce a video having high subjective visual quality when displayed.
The present invention relates to a computerized method and a system for encoding a sequence of video frames. Each frame is organized in blocks of pixels, typically called macroblocks. In terms of the method, the invention determines that a current frame in the sequence of video frames is a change in scene from a previous frame. When it is determined that the current frame is a scene change, the current frame is coded to be an intra frame with each block of pixels of the intra frame being an intra-coded block.
In one aspect, the method determines a coding mode for each block of pixels in the current frame, counts a number of the blocks of pixels of the current frame for which the coding mode is determined to be a particular mode, and compares the number to a predetermined threshold to determine whether the scene change has occurred.
In another aspect of the method, the scene detecting and coding is repeated for each frame in the video sequence to produce a compressed bit stream having a coded intra frame at each scene change. Each coded intra frame provides an access point in the bit stream from which a storyboard of scenes in the video sequence can be generated.
In terms of the system, the invention includes a scene change detector for determining whether a current frame in the sequence of video frames is a scene change from a previous frame, and an encoder for coding the current frame to be an intra frame when the scene change detector determines that the current frame is the scene change.